#ifdef HERZELEID_DESKTOP
 #if _MSC_VER
  #pragma once
 #endif

 #ifndef __HERZELEID_POINTERPOINT_INCLUDED__
  #define __HERZELEID_POINTERPOINT_INCLUDED__
  #include "HerzeleidPointerPointProperties.hxx"
  #include "HerzeleidPointerUpdateKind.hxx"
  #include "HerzeleidCoreWindowMessage.hxx"

HerzeleidUICoreNamespaceBegin
	class PointerEventArgs;
HerzeleidUICoreNamespaceEnd;

HerzeleidUIInputNamespaceBegin
	TypeDecl( POINTER_INFO, __pointer_info, RawPointerInfo );
HerzeleidUIInputNamespaceEnd;

// Provides basic properties for the input pointer associated with a single mouse, pen/stylus, or touch contact.
HerzeleidUIInputNamespaceBegin class PointerPoint 
{
	friend class HerzeleidUICoreNamespaceImpl::PointerEventArgs;
protected:

	typedef HerzeleidUIInputNamespaceImpl::PointerUpdateKind UpdateKind;	// PointerPoint shortcut
	typedef HerzeleidUICoreNamespaceImpl::WindowMessage WindowMessage;		// Window message raw structure. 
	typedef HerzeleidFoundationNamespaceImpl::Point Point;					// Internal point type shortcut. 
	TinyTypeDecl( WindowMessage );											// Window message raw structure.
	TinyTypeDecl( UpdateKind );												// Window message raw structure.
	TinyTypeDecl( Point );													// Internal point type shortcut. 

	PointerPointProperties m_Properties;								// Extended information about the input pointer.
	UInt64 m_uTimestamp64;												// Time when the input occurred. The time, relative to the system boot time, in milliseconds.
	Bool m_bIsInContact;												// A unique identifier for the input pointer.
	UInt32 m_uPointerId;												// A unique identifier for the input pointer.
	Point m_RawPosition;												// Raw location of the pointer input in client coordinates.
	UInt32 m_uFrameId;													// Location of the pointer input in client coordinates.
	Point m_Position;													// Gets a value that indicates whether the physical entity (touch, pen/stylus, or mouse button) is pressed down.
	
	// Configures pointer point members.
	Void Configure(								
		_In_ WindowMessage WindowMessage,								// Raw wnd msg.
		_Maybenull_ RawPointerInfoPtr Info								// Pointer info.
		);

	// Configures pointer point members.
	Void Configure(								
		_In_ WindowMessage WindowMessage,								// Raw wnd msg.
		_In_ UpdateKind Kind											// Update kind.
		);
	
public:

	// Creates an empty object
	PointerPoint( );

	DeclGetPropOnly( PointerPointPropertiesConstPtrConst, Properties );					// Gets extended information about the input pointer.
	DeclGetPropOnly( PointConstPtrConst, RawPosition );									// Gets the raw location of the pointer input in client coordinates.
	DeclGetPropOnly( UInt64Const, Timestamp );											// Gets the time when the input occurred. The time, relative to the system boot time, in milliseconds.
	DeclGetPropOnly( UInt32Const, PointerId );											// Gets a unique identifier for the input pointer.
	DeclGetPropOnly( BoolConst, IsInContact );											// Gets a value that indicates whether the physical entity (touch, pen/stylus, or mouse button) is pressed down.
	DeclGetPropOnly( UInt32Const, FrameId );											// Gets a unique identifier for the input pointer.
	DeclGetPropOnly( PointConstPtrConst, Position );									// Gets the location of the pointer input in client coordinates.

	DeclConstTypedGetterFor( PointerPointPropertiesConstPtrConst, Properties ) { return &m_Properties; } // Gets extended information about the input pointer.
	DeclConstTypedGetterFor( PointConstPtrConst, RawPosition ) { return &m_RawPosition; } // Gets the raw location of the pointer input in client coordinates.
	DeclConstTypedGetterFor( UInt64Const, Timestamp ) { return m_uTimestamp64; } // Gets the time when the input occurred. The time, relative to the system boot time, in milliseconds.
	DeclConstTypedGetterFor( UInt32Const, PointerId ) { return m_uPointerId; } // Gets a unique identifier for the input pointer.
	DeclConstTypedGetterFor( BoolConst, IsInContact ) { return m_bIsInContact; } // Gets a value that indicates whether the physical entity (touch, pen/stylus, or mouse button) is pressed down.
	DeclConstTypedGetterFor( UInt32Const, FrameId ) { return m_uFrameId; } // Gets a unique identifier for the input pointer.
	DeclConstTypedGetterFor( PointConstPtrConst, Position ) { return &m_Position; } // Gets the location of the pointer input in client coordinates.

} HerzeleidUIInputNamespaceEnd; 

HerzeleidUIInputNamespaceBegin
	TinyTypeDecl( PointerPoint );
HerzeleidUIInputNamespaceEnd;

 #endif // !HERZELEID_POINTERPOINT_INCLUDED__
#endif // !HERZELEID_DESKTOP
